/**
 * This file is part of mycollab-services.
 *
 * mycollab-services is free software: you can redistribute it and/or modify
 * it under the terms of the GNU General Public License as published by
 * the Free Software Foundation, either version 3 of the License, or
 * (at your option) any later version.
 *
 * mycollab-services is distributed in the hope that it will be useful,
 * but WITHOUT ANY WARRANTY; without even the implied warranty of
 * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.  See the
 * GNU General Public License for more details.
 *
 * You should have received a copy of the GNU General Public License
 * along with mycollab-services.  If not, see <http://www.gnu.org/licenses/>.
 */
package com.mycollab.module.crm.domain;

import java.util.ArrayList;
import java.util.Date;
import java.util.List;

@SuppressWarnings("ucd")
public class OpportunityExample {
    /**
     * This field was generated by MyBatis Generator.
     * This field corresponds to the database table m_crm_opportunity
     *
     * @mbg.generated Sun Dec 25 21:29:47 ICT 2016
     */
    protected String orderByClause;

    /**
     * This field was generated by MyBatis Generator.
     * This field corresponds to the database table m_crm_opportunity
     *
     * @mbg.generated Sun Dec 25 21:29:47 ICT 2016
     */
    protected boolean distinct;

    /**
     * This field was generated by MyBatis Generator.
     * This field corresponds to the database table m_crm_opportunity
     *
     * @mbg.generated Sun Dec 25 21:29:47 ICT 2016
     */
    protected List<Criteria> oredCriteria;

    /**
     * This method was generated by MyBatis Generator.
     * This method corresponds to the database table m_crm_opportunity
     *
     * @mbg.generated Sun Dec 25 21:29:47 ICT 2016
     */
    public OpportunityExample() {
        oredCriteria = new ArrayList<Criteria>();
    }

    /**
     * This method was generated by MyBatis Generator.
     * This method corresponds to the database table m_crm_opportunity
     *
     * @mbg.generated Sun Dec 25 21:29:47 ICT 2016
     */
    public void setOrderByClause(String orderByClause) {
        this.orderByClause = orderByClause;
    }

    /**
     * This method was generated by MyBatis Generator.
     * This method corresponds to the database table m_crm_opportunity
     *
     * @mbg.generated Sun Dec 25 21:29:47 ICT 2016
     */
    public String getOrderByClause() {
        return orderByClause;
    }

    /**
     * This method was generated by MyBatis Generator.
     * This method corresponds to the database table m_crm_opportunity
     *
     * @mbg.generated Sun Dec 25 21:29:47 ICT 2016
     */
    public void setDistinct(boolean distinct) {
        this.distinct = distinct;
    }

    /**
     * This method was generated by MyBatis Generator.
     * This method corresponds to the database table m_crm_opportunity
     *
     * @mbg.generated Sun Dec 25 21:29:47 ICT 2016
     */
    public boolean isDistinct() {
        return distinct;
    }

    /**
     * This method was generated by MyBatis Generator.
     * This method corresponds to the database table m_crm_opportunity
     *
     * @mbg.generated Sun Dec 25 21:29:47 ICT 2016
     */
    public List<Criteria> getOredCriteria() {
        return oredCriteria;
    }

    /**
     * This method was generated by MyBatis Generator.
     * This method corresponds to the database table m_crm_opportunity
     *
     * @mbg.generated Sun Dec 25 21:29:47 ICT 2016
     */
    public void or(Criteria criteria) {
        oredCriteria.add(criteria);
    }

    /**
     * This method was generated by MyBatis Generator.
     * This method corresponds to the database table m_crm_opportunity
     *
     * @mbg.generated Sun Dec 25 21:29:47 ICT 2016
     */
    public Criteria or() {
        Criteria criteria = createCriteriaInternal();
        oredCriteria.add(criteria);
        return criteria;
    }

    /**
     * This method was generated by MyBatis Generator.
     * This method corresponds to the database table m_crm_opportunity
     *
     * @mbg.generated Sun Dec 25 21:29:47 ICT 2016
     */
    public Criteria createCriteria() {
        Criteria criteria = createCriteriaInternal();
        if (oredCriteria.size() == 0) {
            oredCriteria.add(criteria);
        }
        return criteria;
    }

    /**
     * This method was generated by MyBatis Generator.
     * This method corresponds to the database table m_crm_opportunity
     *
     * @mbg.generated Sun Dec 25 21:29:47 ICT 2016
     */
    protected Criteria createCriteriaInternal() {
        Criteria criteria = new Criteria();
        return criteria;
    }

    /**
     * This method was generated by MyBatis Generator.
     * This method corresponds to the database table m_crm_opportunity
     *
     * @mbg.generated Sun Dec 25 21:29:47 ICT 2016
     */
    public void clear() {
        oredCriteria.clear();
        orderByClause = null;
        distinct = false;
    }

    /**
     * This class was generated by MyBatis Generator.
     * This class corresponds to the database table m_crm_opportunity
     *
     * @mbg.generated Sun Dec 25 21:29:47 ICT 2016
     */
    @SuppressWarnings("ucd")
    protected abstract static class GeneratedCriteria {
        protected List<Criterion> criteria;

        protected GeneratedCriteria() {
            super();
            criteria = new ArrayList<Criterion>();
        }

        public boolean isValid() {
            return criteria.size() > 0;
        }

        public List<Criterion> getAllCriteria() {
            return criteria;
        }

        public List<Criterion> getCriteria() {
            return criteria;
        }

        protected void addCriterion(String condition) {
            if (condition == null) {
                throw new RuntimeException("Value for condition cannot be null");
            }
            criteria.add(new Criterion(condition));
        }

        protected void addCriterion(String condition, Object value, String property) {
            if (value == null) {
                throw new RuntimeException("Value for " + property + " cannot be null");
            }
            criteria.add(new Criterion(condition, value));
        }

        protected void addCriterion(String condition, Object value1, Object value2, String property) {
            if (value1 == null || value2 == null) {
                throw new RuntimeException("Between values for " + property + " cannot be null");
            }
            criteria.add(new Criterion(condition, value1, value2));
        }

        public Criteria andIdIsNull() {
            addCriterion("id is null");
            return (Criteria) this;
        }

        public Criteria andIdIsNotNull() {
            addCriterion("id is not null");
            return (Criteria) this;
        }

        public Criteria andIdEqualTo(Integer value) {
            addCriterion("id =", value, "id");
            return (Criteria) this;
        }

        public Criteria andIdNotEqualTo(Integer value) {
            addCriterion("id <>", value, "id");
            return (Criteria) this;
        }

        public Criteria andIdGreaterThan(Integer value) {
            addCriterion("id >", value, "id");
            return (Criteria) this;
        }

        public Criteria andIdGreaterThanOrEqualTo(Integer value) {
            addCriterion("id >=", value, "id");
            return (Criteria) this;
        }

        public Criteria andIdLessThan(Integer value) {
            addCriterion("id <", value, "id");
            return (Criteria) this;
        }

        public Criteria andIdLessThanOrEqualTo(Integer value) {
            addCriterion("id <=", value, "id");
            return (Criteria) this;
        }

        public Criteria andIdIn(List<Integer> values) {
            addCriterion("id in", values, "id");
            return (Criteria) this;
        }

        public Criteria andIdNotIn(List<Integer> values) {
            addCriterion("id not in", values, "id");
            return (Criteria) this;
        }

        public Criteria andIdBetween(Integer value1, Integer value2) {
            addCriterion("id between", value1, value2, "id");
            return (Criteria) this;
        }

        public Criteria andIdNotBetween(Integer value1, Integer value2) {
            addCriterion("id not between", value1, value2, "id");
            return (Criteria) this;
        }

        public Criteria andOpportunitynameIsNull() {
            addCriterion("opportunityName is null");
            return (Criteria) this;
        }

        public Criteria andOpportunitynameIsNotNull() {
            addCriterion("opportunityName is not null");
            return (Criteria) this;
        }

        public Criteria andOpportunitynameEqualTo(String value) {
            addCriterion("opportunityName =", value, "opportunityname");
            return (Criteria) this;
        }

        public Criteria andOpportunitynameNotEqualTo(String value) {
            addCriterion("opportunityName <>", value, "opportunityname");
            return (Criteria) this;
        }

        public Criteria andOpportunitynameGreaterThan(String value) {
            addCriterion("opportunityName >", value, "opportunityname");
            return (Criteria) this;
        }

        public Criteria andOpportunitynameGreaterThanOrEqualTo(String value) {
            addCriterion("opportunityName >=", value, "opportunityname");
            return (Criteria) this;
        }

        public Criteria andOpportunitynameLessThan(String value) {
            addCriterion("opportunityName <", value, "opportunityname");
            return (Criteria) this;
        }

        public Criteria andOpportunitynameLessThanOrEqualTo(String value) {
            addCriterion("opportunityName <=", value, "opportunityname");
            return (Criteria) this;
        }

        public Criteria andOpportunitynameLike(String value) {
            addCriterion("opportunityName like", value, "opportunityname");
            return (Criteria) this;
        }

        public Criteria andOpportunitynameNotLike(String value) {
            addCriterion("opportunityName not like", value, "opportunityname");
            return (Criteria) this;
        }

        public Criteria andOpportunitynameIn(List<String> values) {
            addCriterion("opportunityName in", values, "opportunityname");
            return (Criteria) this;
        }

        public Criteria andOpportunitynameNotIn(List<String> values) {
            addCriterion("opportunityName not in", values, "opportunityname");
            return (Criteria) this;
        }

        public Criteria andOpportunitynameBetween(String value1, String value2) {
            addCriterion("opportunityName between", value1, value2, "opportunityname");
            return (Criteria) this;
        }

        public Criteria andOpportunitynameNotBetween(String value1, String value2) {
            addCriterion("opportunityName not between", value1, value2, "opportunityname");
            return (Criteria) this;
        }

        public Criteria andCurrencyidIsNull() {
            addCriterion("currencyid is null");
            return (Criteria) this;
        }

        public Criteria andCurrencyidIsNotNull() {
            addCriterion("currencyid is not null");
            return (Criteria) this;
        }

        public Criteria andCurrencyidEqualTo(String value) {
            addCriterion("currencyid =", value, "currencyid");
            return (Criteria) this;
        }

        public Criteria andCurrencyidNotEqualTo(String value) {
            addCriterion("currencyid <>", value, "currencyid");
            return (Criteria) this;
        }

        public Criteria andCurrencyidGreaterThan(String value) {
            addCriterion("currencyid >", value, "currencyid");
            return (Criteria) this;
        }

        public Criteria andCurrencyidGreaterThanOrEqualTo(String value) {
            addCriterion("currencyid >=", value, "currencyid");
            return (Criteria) this;
        }

        public Criteria andCurrencyidLessThan(String value) {
            addCriterion("currencyid <", value, "currencyid");
            return (Criteria) this;
        }

        public Criteria andCurrencyidLessThanOrEqualTo(String value) {
            addCriterion("currencyid <=", value, "currencyid");
            return (Criteria) this;
        }

        public Criteria andCurrencyidLike(String value) {
            addCriterion("currencyid like", value, "currencyid");
            return (Criteria) this;
        }

        public Criteria andCurrencyidNotLike(String value) {
            addCriterion("currencyid not like", value, "currencyid");
            return (Criteria) this;
        }

        public Criteria andCurrencyidIn(List<String> values) {
            addCriterion("currencyid in", values, "currencyid");
            return (Criteria) this;
        }

        public Criteria andCurrencyidNotIn(List<String> values) {
            addCriterion("currencyid not in", values, "currencyid");
            return (Criteria) this;
        }

        public Criteria andCurrencyidBetween(String value1, String value2) {
            addCriterion("currencyid between", value1, value2, "currencyid");
            return (Criteria) this;
        }

        public Criteria andCurrencyidNotBetween(String value1, String value2) {
            addCriterion("currencyid not between", value1, value2, "currencyid");
            return (Criteria) this;
        }

        public Criteria andAccountidIsNull() {
            addCriterion("accountid is null");
            return (Criteria) this;
        }

        public Criteria andAccountidIsNotNull() {
            addCriterion("accountid is not null");
            return (Criteria) this;
        }

        public Criteria andAccountidEqualTo(Integer value) {
            addCriterion("accountid =", value, "accountid");
            return (Criteria) this;
        }

        public Criteria andAccountidNotEqualTo(Integer value) {
            addCriterion("accountid <>", value, "accountid");
            return (Criteria) this;
        }

        public Criteria andAccountidGreaterThan(Integer value) {
            addCriterion("accountid >", value, "accountid");
            return (Criteria) this;
        }

        public Criteria andAccountidGreaterThanOrEqualTo(Integer value) {
            addCriterion("accountid >=", value, "accountid");
            return (Criteria) this;
        }

        public Criteria andAccountidLessThan(Integer value) {
            addCriterion("accountid <", value, "accountid");
            return (Criteria) this;
        }

        public Criteria andAccountidLessThanOrEqualTo(Integer value) {
            addCriterion("accountid <=", value, "accountid");
            return (Criteria) this;
        }

        public Criteria andAccountidIn(List<Integer> values) {
            addCriterion("accountid in", values, "accountid");
            return (Criteria) this;
        }

        public Criteria andAccountidNotIn(List<Integer> values) {
            addCriterion("accountid not in", values, "accountid");
            return (Criteria) this;
        }

        public Criteria andAccountidBetween(Integer value1, Integer value2) {
            addCriterion("accountid between", value1, value2, "accountid");
            return (Criteria) this;
        }

        public Criteria andAccountidNotBetween(Integer value1, Integer value2) {
            addCriterion("accountid not between", value1, value2, "accountid");
            return (Criteria) this;
        }

        public Criteria andAmountIsNull() {
            addCriterion("amount is null");
            return (Criteria) this;
        }

        public Criteria andAmountIsNotNull() {
            addCriterion("amount is not null");
            return (Criteria) this;
        }

        public Criteria andAmountEqualTo(Double value) {
            addCriterion("amount =", value, "amount");
            return (Criteria) this;
        }

        public Criteria andAmountNotEqualTo(Double value) {
            addCriterion("amount <>", value, "amount");
            return (Criteria) this;
        }

        public Criteria andAmountGreaterThan(Double value) {
            addCriterion("amount >", value, "amount");
            return (Criteria) this;
        }

        public Criteria andAmountGreaterThanOrEqualTo(Double value) {
            addCriterion("amount >=", value, "amount");
            return (Criteria) this;
        }

        public Criteria andAmountLessThan(Double value) {
            addCriterion("amount <", value, "amount");
            return (Criteria) this;
        }

        public Criteria andAmountLessThanOrEqualTo(Double value) {
            addCriterion("amount <=", value, "amount");
            return (Criteria) this;
        }

        public Criteria andAmountIn(List<Double> values) {
            addCriterion("amount in", values, "amount");
            return (Criteria) this;
        }

        public Criteria andAmountNotIn(List<Double> values) {
            addCriterion("amount not in", values, "amount");
            return (Criteria) this;
        }

        public Criteria andAmountBetween(Double value1, Double value2) {
            addCriterion("amount between", value1, value2, "amount");
            return (Criteria) this;
        }

        public Criteria andAmountNotBetween(Double value1, Double value2) {
            addCriterion("amount not between", value1, value2, "amount");
            return (Criteria) this;
        }

        public Criteria andTypeIsNull() {
            addCriterion("type is null");
            return (Criteria) this;
        }

        public Criteria andTypeIsNotNull() {
            addCriterion("type is not null");
            return (Criteria) this;
        }

        public Criteria andTypeEqualTo(String value) {
            addCriterion("type =", value, "type");
            return (Criteria) this;
        }

        public Criteria andTypeNotEqualTo(String value) {
            addCriterion("type <>", value, "type");
            return (Criteria) this;
        }

        public Criteria andTypeGreaterThan(String value) {
            addCriterion("type >", value, "type");
            return (Criteria) this;
        }

        public Criteria andTypeGreaterThanOrEqualTo(String value) {
            addCriterion("type >=", value, "type");
            return (Criteria) this;
        }

        public Criteria andTypeLessThan(String value) {
            addCriterion("type <", value, "type");
            return (Criteria) this;
        }

        public Criteria andTypeLessThanOrEqualTo(String value) {
            addCriterion("type <=", value, "type");
            return (Criteria) this;
        }

        public Criteria andTypeLike(String value) {
            addCriterion("type like", value, "type");
            return (Criteria) this;
        }

        public Criteria andTypeNotLike(String value) {
            addCriterion("type not like", value, "type");
            return (Criteria) this;
        }

        public Criteria andTypeIn(List<String> values) {
            addCriterion("type in", values, "type");
            return (Criteria) this;
        }

        public Criteria andTypeNotIn(List<String> values) {
            addCriterion("type not in", values, "type");
            return (Criteria) this;
        }

        public Criteria andTypeBetween(String value1, String value2) {
            addCriterion("type between", value1, value2, "type");
            return (Criteria) this;
        }

        public Criteria andTypeNotBetween(String value1, String value2) {
            addCriterion("type not between", value1, value2, "type");
            return (Criteria) this;
        }

        public Criteria andSourceIsNull() {
            addCriterion("source is null");
            return (Criteria) this;
        }

        public Criteria andSourceIsNotNull() {
            addCriterion("source is not null");
            return (Criteria) this;
        }

        public Criteria andSourceEqualTo(String value) {
            addCriterion("source =", value, "source");
            return (Criteria) this;
        }

        public Criteria andSourceNotEqualTo(String value) {
            addCriterion("source <>", value, "source");
            return (Criteria) this;
        }

        public Criteria andSourceGreaterThan(String value) {
            addCriterion("source >", value, "source");
            return (Criteria) this;
        }

        public Criteria andSourceGreaterThanOrEqualTo(String value) {
            addCriterion("source >=", value, "source");
            return (Criteria) this;
        }

        public Criteria andSourceLessThan(String value) {
            addCriterion("source <", value, "source");
            return (Criteria) this;
        }

        public Criteria andSourceLessThanOrEqualTo(String value) {
            addCriterion("source <=", value, "source");
            return (Criteria) this;
        }

        public Criteria andSourceLike(String value) {
            addCriterion("source like", value, "source");
            return (Criteria) this;
        }

        public Criteria andSourceNotLike(String value) {
            addCriterion("source not like", value, "source");
            return (Criteria) this;
        }

        public Criteria andSourceIn(List<String> values) {
            addCriterion("source in", values, "source");
            return (Criteria) this;
        }

        public Criteria andSourceNotIn(List<String> values) {
            addCriterion("source not in", values, "source");
            return (Criteria) this;
        }

        public Criteria andSourceBetween(String value1, String value2) {
            addCriterion("source between", value1, value2, "source");
            return (Criteria) this;
        }

        public Criteria andSourceNotBetween(String value1, String value2) {
            addCriterion("source not between", value1, value2, "source");
            return (Criteria) this;
        }

        public Criteria andExpectedcloseddateIsNull() {
            addCriterion("expectedClosedDate is null");
            return (Criteria) this;
        }

        public Criteria andExpectedcloseddateIsNotNull() {
            addCriterion("expectedClosedDate is not null");
            return (Criteria) this;
        }

        public Criteria andExpectedcloseddateEqualTo(Date value) {
            addCriterion("expectedClosedDate =", value, "expectedcloseddate");
            return (Criteria) this;
        }

        public Criteria andExpectedcloseddateNotEqualTo(Date value) {
            addCriterion("expectedClosedDate <>", value, "expectedcloseddate");
            return (Criteria) this;
        }

        public Criteria andExpectedcloseddateGreaterThan(Date value) {
            addCriterion("expectedClosedDate >", value, "expectedcloseddate");
            return (Criteria) this;
        }

        public Criteria andExpectedcloseddateGreaterThanOrEqualTo(Date value) {
            addCriterion("expectedClosedDate >=", value, "expectedcloseddate");
            return (Criteria) this;
        }

        public Criteria andExpectedcloseddateLessThan(Date value) {
            addCriterion("expectedClosedDate <", value, "expectedcloseddate");
            return (Criteria) this;
        }

        public Criteria andExpectedcloseddateLessThanOrEqualTo(Date value) {
            addCriterion("expectedClosedDate <=", value, "expectedcloseddate");
            return (Criteria) this;
        }

        public Criteria andExpectedcloseddateIn(List<Date> values) {
            addCriterion("expectedClosedDate in", values, "expectedcloseddate");
            return (Criteria) this;
        }

        public Criteria andExpectedcloseddateNotIn(List<Date> values) {
            addCriterion("expectedClosedDate not in", values, "expectedcloseddate");
            return (Criteria) this;
        }

        public Criteria andExpectedcloseddateBetween(Date value1, Date value2) {
            addCriterion("expectedClosedDate between", value1, value2, "expectedcloseddate");
            return (Criteria) this;
        }

        public Criteria andExpectedcloseddateNotBetween(Date value1, Date value2) {
            addCriterion("expectedClosedDate not between", value1, value2, "expectedcloseddate");
            return (Criteria) this;
        }

        public Criteria andCampaignidIsNull() {
            addCriterion("campaignid is null");
            return (Criteria) this;
        }

        public Criteria andCampaignidIsNotNull() {
            addCriterion("campaignid is not null");
            return (Criteria) this;
        }

        public Criteria andCampaignidEqualTo(Integer value) {
            addCriterion("campaignid =", value, "campaignid");
            return (Criteria) this;
        }

        public Criteria andCampaignidNotEqualTo(Integer value) {
            addCriterion("campaignid <>", value, "campaignid");
            return (Criteria) this;
        }

        public Criteria andCampaignidGreaterThan(Integer value) {
            addCriterion("campaignid >", value, "campaignid");
            return (Criteria) this;
        }

        public Criteria andCampaignidGreaterThanOrEqualTo(Integer value) {
            addCriterion("campaignid >=", value, "campaignid");
            return (Criteria) this;
        }

        public Criteria andCampaignidLessThan(Integer value) {
            addCriterion("campaignid <", value, "campaignid");
            return (Criteria) this;
        }

        public Criteria andCampaignidLessThanOrEqualTo(Integer value) {
            addCriterion("campaignid <=", value, "campaignid");
            return (Criteria) this;
        }

        public Criteria andCampaignidIn(List<Integer> values) {
            addCriterion("campaignid in", values, "campaignid");
            return (Criteria) this;
        }

        public Criteria andCampaignidNotIn(List<Integer> values) {
            addCriterion("campaignid not in", values, "campaignid");
            return (Criteria) this;
        }

        public Criteria andCampaignidBetween(Integer value1, Integer value2) {
            addCriterion("campaignid between", value1, value2, "campaignid");
            return (Criteria) this;
        }

        public Criteria andCampaignidNotBetween(Integer value1, Integer value2) {
            addCriterion("campaignid not between", value1, value2, "campaignid");
            return (Criteria) this;
        }

        public Criteria andNextstepIsNull() {
            addCriterion("nextStep is null");
            return (Criteria) this;
        }

        public Criteria andNextstepIsNotNull() {
            addCriterion("nextStep is not null");
            return (Criteria) this;
        }

        public Criteria andNextstepEqualTo(String value) {
            addCriterion("nextStep =", value, "nextstep");
            return (Criteria) this;
        }

        public Criteria andNextstepNotEqualTo(String value) {
            addCriterion("nextStep <>", value, "nextstep");
            return (Criteria) this;
        }

        public Criteria andNextstepGreaterThan(String value) {
            addCriterion("nextStep >", value, "nextstep");
            return (Criteria) this;
        }

        public Criteria andNextstepGreaterThanOrEqualTo(String value) {
            addCriterion("nextStep >=", value, "nextstep");
            return (Criteria) this;
        }

        public Criteria andNextstepLessThan(String value) {
            addCriterion("nextStep <", value, "nextstep");
            return (Criteria) this;
        }

        public Criteria andNextstepLessThanOrEqualTo(String value) {
            addCriterion("nextStep <=", value, "nextstep");
            return (Criteria) this;
        }

        public Criteria andNextstepLike(String value) {
            addCriterion("nextStep like", value, "nextstep");
            return (Criteria) this;
        }

        public Criteria andNextstepNotLike(String value) {
            addCriterion("nextStep not like", value, "nextstep");
            return (Criteria) this;
        }

        public Criteria andNextstepIn(List<String> values) {
            addCriterion("nextStep in", values, "nextstep");
            return (Criteria) this;
        }

        public Criteria andNextstepNotIn(List<String> values) {
            addCriterion("nextStep not in", values, "nextstep");
            return (Criteria) this;
        }

        public Criteria andNextstepBetween(String value1, String value2) {
            addCriterion("nextStep between", value1, value2, "nextstep");
            return (Criteria) this;
        }

        public Criteria andNextstepNotBetween(String value1, String value2) {
            addCriterion("nextStep not between", value1, value2, "nextstep");
            return (Criteria) this;
        }

        public Criteria andProbabilityIsNull() {
            addCriterion("probability is null");
            return (Criteria) this;
        }

        public Criteria andProbabilityIsNotNull() {
            addCriterion("probability is not null");
            return (Criteria) this;
        }

        public Criteria andProbabilityEqualTo(Integer value) {
            addCriterion("probability =", value, "probability");
            return (Criteria) this;
        }

        public Criteria andProbabilityNotEqualTo(Integer value) {
            addCriterion("probability <>", value, "probability");
            return (Criteria) this;
        }

        public Criteria andProbabilityGreaterThan(Integer value) {
            addCriterion("probability >", value, "probability");
            return (Criteria) this;
        }

        public Criteria andProbabilityGreaterThanOrEqualTo(Integer value) {
            addCriterion("probability >=", value, "probability");
            return (Criteria) this;
        }

        public Criteria andProbabilityLessThan(Integer value) {
            addCriterion("probability <", value, "probability");
            return (Criteria) this;
        }

        public Criteria andProbabilityLessThanOrEqualTo(Integer value) {
            addCriterion("probability <=", value, "probability");
            return (Criteria) this;
        }

        public Criteria andProbabilityIn(List<Integer> values) {
            addCriterion("probability in", values, "probability");
            return (Criteria) this;
        }

        public Criteria andProbabilityNotIn(List<Integer> values) {
            addCriterion("probability not in", values, "probability");
            return (Criteria) this;
        }

        public Criteria andProbabilityBetween(Integer value1, Integer value2) {
            addCriterion("probability between", value1, value2, "probability");
            return (Criteria) this;
        }

        public Criteria andProbabilityNotBetween(Integer value1, Integer value2) {
            addCriterion("probability not between", value1, value2, "probability");
            return (Criteria) this;
        }

        public Criteria andCreatedtimeIsNull() {
            addCriterion("createdTime is null");
            return (Criteria) this;
        }

        public Criteria andCreatedtimeIsNotNull() {
            addCriterion("createdTime is not null");
            return (Criteria) this;
        }

        public Criteria andCreatedtimeEqualTo(Date value) {
            addCriterion("createdTime =", value, "createdtime");
            return (Criteria) this;
        }

        public Criteria andCreatedtimeNotEqualTo(Date value) {
            addCriterion("createdTime <>", value, "createdtime");
            return (Criteria) this;
        }

        public Criteria andCreatedtimeGreaterThan(Date value) {
            addCriterion("createdTime >", value, "createdtime");
            return (Criteria) this;
        }

        public Criteria andCreatedtimeGreaterThanOrEqualTo(Date value) {
            addCriterion("createdTime >=", value, "createdtime");
            return (Criteria) this;
        }

        public Criteria andCreatedtimeLessThan(Date value) {
            addCriterion("createdTime <", value, "createdtime");
            return (Criteria) this;
        }

        public Criteria andCreatedtimeLessThanOrEqualTo(Date value) {
            addCriterion("createdTime <=", value, "createdtime");
            return (Criteria) this;
        }

        public Criteria andCreatedtimeIn(List<Date> values) {
            addCriterion("createdTime in", values, "createdtime");
            return (Criteria) this;
        }

        public Criteria andCreatedtimeNotIn(List<Date> values) {
            addCriterion("createdTime not in", values, "createdtime");
            return (Criteria) this;
        }

        public Criteria andCreatedtimeBetween(Date value1, Date value2) {
            addCriterion("createdTime between", value1, value2, "createdtime");
            return (Criteria) this;
        }

        public Criteria andCreatedtimeNotBetween(Date value1, Date value2) {
            addCriterion("createdTime not between", value1, value2, "createdtime");
            return (Criteria) this;
        }

        public Criteria andCreateduserIsNull() {
            addCriterion("createdUser is null");
            return (Criteria) this;
        }

        public Criteria andCreateduserIsNotNull() {
            addCriterion("createdUser is not null");
            return (Criteria) this;
        }

        public Criteria andCreateduserEqualTo(String value) {
            addCriterion("createdUser =", value, "createduser");
            return (Criteria) this;
        }

        public Criteria andCreateduserNotEqualTo(String value) {
            addCriterion("createdUser <>", value, "createduser");
            return (Criteria) this;
        }

        public Criteria andCreateduserGreaterThan(String value) {
            addCriterion("createdUser >", value, "createduser");
            return (Criteria) this;
        }

        public Criteria andCreateduserGreaterThanOrEqualTo(String value) {
            addCriterion("createdUser >=", value, "createduser");
            return (Criteria) this;
        }

        public Criteria andCreateduserLessThan(String value) {
            addCriterion("createdUser <", value, "createduser");
            return (Criteria) this;
        }

        public Criteria andCreateduserLessThanOrEqualTo(String value) {
            addCriterion("createdUser <=", value, "createduser");
            return (Criteria) this;
        }

        public Criteria andCreateduserLike(String value) {
            addCriterion("createdUser like", value, "createduser");
            return (Criteria) this;
        }

        public Criteria andCreateduserNotLike(String value) {
            addCriterion("createdUser not like", value, "createduser");
            return (Criteria) this;
        }

        public Criteria andCreateduserIn(List<String> values) {
            addCriterion("createdUser in", values, "createduser");
            return (Criteria) this;
        }

        public Criteria andCreateduserNotIn(List<String> values) {
            addCriterion("createdUser not in", values, "createduser");
            return (Criteria) this;
        }

        public Criteria andCreateduserBetween(String value1, String value2) {
            addCriterion("createdUser between", value1, value2, "createduser");
            return (Criteria) this;
        }

        public Criteria andCreateduserNotBetween(String value1, String value2) {
            addCriterion("createdUser not between", value1, value2, "createduser");
            return (Criteria) this;
        }

        public Criteria andSaccountidIsNull() {
            addCriterion("sAccountId is null");
            return (Criteria) this;
        }

        public Criteria andSaccountidIsNotNull() {
            addCriterion("sAccountId is not null");
            return (Criteria) this;
        }

        public Criteria andSaccountidEqualTo(Integer value) {
            addCriterion("sAccountId =", value, "saccountid");
            return (Criteria) this;
        }

        public Criteria andSaccountidNotEqualTo(Integer value) {
            addCriterion("sAccountId <>", value, "saccountid");
            return (Criteria) this;
        }

        public Criteria andSaccountidGreaterThan(Integer value) {
            addCriterion("sAccountId >", value, "saccountid");
            return (Criteria) this;
        }

        public Criteria andSaccountidGreaterThanOrEqualTo(Integer value) {
            addCriterion("sAccountId >=", value, "saccountid");
            return (Criteria) this;
        }

        public Criteria andSaccountidLessThan(Integer value) {
            addCriterion("sAccountId <", value, "saccountid");
            return (Criteria) this;
        }

        public Criteria andSaccountidLessThanOrEqualTo(Integer value) {
            addCriterion("sAccountId <=", value, "saccountid");
            return (Criteria) this;
        }

        public Criteria andSaccountidIn(List<Integer> values) {
            addCriterion("sAccountId in", values, "saccountid");
            return (Criteria) this;
        }

        public Criteria andSaccountidNotIn(List<Integer> values) {
            addCriterion("sAccountId not in", values, "saccountid");
            return (Criteria) this;
        }

        public Criteria andSaccountidBetween(Integer value1, Integer value2) {
            addCriterion("sAccountId between", value1, value2, "saccountid");
            return (Criteria) this;
        }

        public Criteria andSaccountidNotBetween(Integer value1, Integer value2) {
            addCriterion("sAccountId not between", value1, value2, "saccountid");
            return (Criteria) this;
        }

        public Criteria andAssignuserIsNull() {
            addCriterion("assignUser is null");
            return (Criteria) this;
        }

        public Criteria andAssignuserIsNotNull() {
            addCriterion("assignUser is not null");
            return (Criteria) this;
        }

        public Criteria andAssignuserEqualTo(String value) {
            addCriterion("assignUser =", value, "assignuser");
            return (Criteria) this;
        }

        public Criteria andAssignuserNotEqualTo(String value) {
            addCriterion("assignUser <>", value, "assignuser");
            return (Criteria) this;
        }

        public Criteria andAssignuserGreaterThan(String value) {
            addCriterion("assignUser >", value, "assignuser");
            return (Criteria) this;
        }

        public Criteria andAssignuserGreaterThanOrEqualTo(String value) {
            addCriterion("assignUser >=", value, "assignuser");
            return (Criteria) this;
        }

        public Criteria andAssignuserLessThan(String value) {
            addCriterion("assignUser <", value, "assignuser");
            return (Criteria) this;
        }

        public Criteria andAssignuserLessThanOrEqualTo(String value) {
            addCriterion("assignUser <=", value, "assignuser");
            return (Criteria) this;
        }

        public Criteria andAssignuserLike(String value) {
            addCriterion("assignUser like", value, "assignuser");
            return (Criteria) this;
        }

        public Criteria andAssignuserNotLike(String value) {
            addCriterion("assignUser not like", value, "assignuser");
            return (Criteria) this;
        }

        public Criteria andAssignuserIn(List<String> values) {
            addCriterion("assignUser in", values, "assignuser");
            return (Criteria) this;
        }

        public Criteria andAssignuserNotIn(List<String> values) {
            addCriterion("assignUser not in", values, "assignuser");
            return (Criteria) this;
        }

        public Criteria andAssignuserBetween(String value1, String value2) {
            addCriterion("assignUser between", value1, value2, "assignuser");
            return (Criteria) this;
        }

        public Criteria andAssignuserNotBetween(String value1, String value2) {
            addCriterion("assignUser not between", value1, value2, "assignuser");
            return (Criteria) this;
        }

        public Criteria andOpportunitytypeIsNull() {
            addCriterion("opportunityType is null");
            return (Criteria) this;
        }

        public Criteria andOpportunitytypeIsNotNull() {
            addCriterion("opportunityType is not null");
            return (Criteria) this;
        }

        public Criteria andOpportunitytypeEqualTo(String value) {
            addCriterion("opportunityType =", value, "opportunitytype");
            return (Criteria) this;
        }

        public Criteria andOpportunitytypeNotEqualTo(String value) {
            addCriterion("opportunityType <>", value, "opportunitytype");
            return (Criteria) this;
        }

        public Criteria andOpportunitytypeGreaterThan(String value) {
            addCriterion("opportunityType >", value, "opportunitytype");
            return (Criteria) this;
        }

        public Criteria andOpportunitytypeGreaterThanOrEqualTo(String value) {
            addCriterion("opportunityType >=", value, "opportunitytype");
            return (Criteria) this;
        }

        public Criteria andOpportunitytypeLessThan(String value) {
            addCriterion("opportunityType <", value, "opportunitytype");
            return (Criteria) this;
        }

        public Criteria andOpportunitytypeLessThanOrEqualTo(String value) {
            addCriterion("opportunityType <=", value, "opportunitytype");
            return (Criteria) this;
        }

        public Criteria andOpportunitytypeLike(String value) {
            addCriterion("opportunityType like", value, "opportunitytype");
            return (Criteria) this;
        }

        public Criteria andOpportunitytypeNotLike(String value) {
            addCriterion("opportunityType not like", value, "opportunitytype");
            return (Criteria) this;
        }

        public Criteria andOpportunitytypeIn(List<String> values) {
            addCriterion("opportunityType in", values, "opportunitytype");
            return (Criteria) this;
        }

        public Criteria andOpportunitytypeNotIn(List<String> values) {
            addCriterion("opportunityType not in", values, "opportunitytype");
            return (Criteria) this;
        }

        public Criteria andOpportunitytypeBetween(String value1, String value2) {
            addCriterion("opportunityType between", value1, value2, "opportunitytype");
            return (Criteria) this;
        }

        public Criteria andOpportunitytypeNotBetween(String value1, String value2) {
            addCriterion("opportunityType not between", value1, value2, "opportunitytype");
            return (Criteria) this;
        }

        public Criteria andSalesstageIsNull() {
            addCriterion("salesStage is null");
            return (Criteria) this;
        }

        public Criteria andSalesstageIsNotNull() {
            addCriterion("salesStage is not null");
            return (Criteria) this;
        }

        public Criteria andSalesstageEqualTo(String value) {
            addCriterion("salesStage =", value, "salesstage");
            return (Criteria) this;
        }

        public Criteria andSalesstageNotEqualTo(String value) {
            addCriterion("salesStage <>", value, "salesstage");
            return (Criteria) this;
        }

        public Criteria andSalesstageGreaterThan(String value) {
            addCriterion("salesStage >", value, "salesstage");
            return (Criteria) this;
        }

        public Criteria andSalesstageGreaterThanOrEqualTo(String value) {
            addCriterion("salesStage >=", value, "salesstage");
            return (Criteria) this;
        }

        public Criteria andSalesstageLessThan(String value) {
            addCriterion("salesStage <", value, "salesstage");
            return (Criteria) this;
        }

        public Criteria andSalesstageLessThanOrEqualTo(String value) {
            addCriterion("salesStage <=", value, "salesstage");
            return (Criteria) this;
        }

        public Criteria andSalesstageLike(String value) {
            addCriterion("salesStage like", value, "salesstage");
            return (Criteria) this;
        }

        public Criteria andSalesstageNotLike(String value) {
            addCriterion("salesStage not like", value, "salesstage");
            return (Criteria) this;
        }

        public Criteria andSalesstageIn(List<String> values) {
            addCriterion("salesStage in", values, "salesstage");
            return (Criteria) this;
        }

        public Criteria andSalesstageNotIn(List<String> values) {
            addCriterion("salesStage not in", values, "salesstage");
            return (Criteria) this;
        }

        public Criteria andSalesstageBetween(String value1, String value2) {
            addCriterion("salesStage between", value1, value2, "salesstage");
            return (Criteria) this;
        }

        public Criteria andSalesstageNotBetween(String value1, String value2) {
            addCriterion("salesStage not between", value1, value2, "salesstage");
            return (Criteria) this;
        }

        public Criteria andLastupdatedtimeIsNull() {
            addCriterion("lastUpdatedTime is null");
            return (Criteria) this;
        }

        public Criteria andLastupdatedtimeIsNotNull() {
            addCriterion("lastUpdatedTime is not null");
            return (Criteria) this;
        }

        public Criteria andLastupdatedtimeEqualTo(Date value) {
            addCriterion("lastUpdatedTime =", value, "lastupdatedtime");
            return (Criteria) this;
        }

        public Criteria andLastupdatedtimeNotEqualTo(Date value) {
            addCriterion("lastUpdatedTime <>", value, "lastupdatedtime");
            return (Criteria) this;
        }

        public Criteria andLastupdatedtimeGreaterThan(Date value) {
            addCriterion("lastUpdatedTime >", value, "lastupdatedtime");
            return (Criteria) this;
        }

        public Criteria andLastupdatedtimeGreaterThanOrEqualTo(Date value) {
            addCriterion("lastUpdatedTime >=", value, "lastupdatedtime");
            return (Criteria) this;
        }

        public Criteria andLastupdatedtimeLessThan(Date value) {
            addCriterion("lastUpdatedTime <", value, "lastupdatedtime");
            return (Criteria) this;
        }

        public Criteria andLastupdatedtimeLessThanOrEqualTo(Date value) {
            addCriterion("lastUpdatedTime <=", value, "lastupdatedtime");
            return (Criteria) this;
        }

        public Criteria andLastupdatedtimeIn(List<Date> values) {
            addCriterion("lastUpdatedTime in", values, "lastupdatedtime");
            return (Criteria) this;
        }

        public Criteria andLastupdatedtimeNotIn(List<Date> values) {
            addCriterion("lastUpdatedTime not in", values, "lastupdatedtime");
            return (Criteria) this;
        }

        public Criteria andLastupdatedtimeBetween(Date value1, Date value2) {
            addCriterion("lastUpdatedTime between", value1, value2, "lastupdatedtime");
            return (Criteria) this;
        }

        public Criteria andLastupdatedtimeNotBetween(Date value1, Date value2) {
            addCriterion("lastUpdatedTime not between", value1, value2, "lastupdatedtime");
            return (Criteria) this;
        }

        public Criteria andAvataridIsNull() {
            addCriterion("avatarId is null");
            return (Criteria) this;
        }

        public Criteria andAvataridIsNotNull() {
            addCriterion("avatarId is not null");
            return (Criteria) this;
        }

        public Criteria andAvataridEqualTo(String value) {
            addCriterion("avatarId =", value, "avatarid");
            return (Criteria) this;
        }

        public Criteria andAvataridNotEqualTo(String value) {
            addCriterion("avatarId <>", value, "avatarid");
            return (Criteria) this;
        }

        public Criteria andAvataridGreaterThan(String value) {
            addCriterion("avatarId >", value, "avatarid");
            return (Criteria) this;
        }

        public Criteria andAvataridGreaterThanOrEqualTo(String value) {
            addCriterion("avatarId >=", value, "avatarid");
            return (Criteria) this;
        }

        public Criteria andAvataridLessThan(String value) {
            addCriterion("avatarId <", value, "avatarid");
            return (Criteria) this;
        }

        public Criteria andAvataridLessThanOrEqualTo(String value) {
            addCriterion("avatarId <=", value, "avatarid");
            return (Criteria) this;
        }

        public Criteria andAvataridLike(String value) {
            addCriterion("avatarId like", value, "avatarid");
            return (Criteria) this;
        }

        public Criteria andAvataridNotLike(String value) {
            addCriterion("avatarId not like", value, "avatarid");
            return (Criteria) this;
        }

        public Criteria andAvataridIn(List<String> values) {
            addCriterion("avatarId in", values, "avatarid");
            return (Criteria) this;
        }

        public Criteria andAvataridNotIn(List<String> values) {
            addCriterion("avatarId not in", values, "avatarid");
            return (Criteria) this;
        }

        public Criteria andAvataridBetween(String value1, String value2) {
            addCriterion("avatarId between", value1, value2, "avatarid");
            return (Criteria) this;
        }

        public Criteria andAvataridNotBetween(String value1, String value2) {
            addCriterion("avatarId not between", value1, value2, "avatarid");
            return (Criteria) this;
        }
    }

    /**
     * This class was generated by MyBatis Generator.
     * This class corresponds to the database table m_crm_opportunity
     *
     * @mbg.generated do_not_delete_during_merge Sun Dec 25 21:29:47 ICT 2016
     */
    @SuppressWarnings("ucd")
    public static class Criteria extends GeneratedCriteria {

        protected Criteria() {
            super();
        }
    }

    /**
     * This class was generated by MyBatis Generator.
     * This class corresponds to the database table m_crm_opportunity
     *
     * @mbg.generated Sun Dec 25 21:29:47 ICT 2016
     */
    @SuppressWarnings("ucd")
    public static class Criterion {
        private String condition;

        private Object value;

        private Object secondValue;

        private boolean noValue;

        private boolean singleValue;

        private boolean betweenValue;

        private boolean listValue;

        private String typeHandler;

        public String getCondition() {
            return condition;
        }

        public Object getValue() {
            return value;
        }

        public Object getSecondValue() {
            return secondValue;
        }

        public boolean isNoValue() {
            return noValue;
        }

        public boolean isSingleValue() {
            return singleValue;
        }

        public boolean isBetweenValue() {
            return betweenValue;
        }

        public boolean isListValue() {
            return listValue;
        }

        public String getTypeHandler() {
            return typeHandler;
        }

        protected Criterion(String condition) {
            super();
            this.condition = condition;
            this.typeHandler = null;
            this.noValue = true;
        }

        protected Criterion(String condition, Object value, String typeHandler) {
            super();
            this.condition = condition;
            this.value = value;
            this.typeHandler = typeHandler;
            if (value instanceof List<?>) {
                this.listValue = true;
            } else {
                this.singleValue = true;
            }
        }

        protected Criterion(String condition, Object value) {
            this(condition, value, null);
        }

        protected Criterion(String condition, Object value, Object secondValue, String typeHandler) {
            super();
            this.condition = condition;
            this.value = value;
            this.secondValue = secondValue;
            this.typeHandler = typeHandler;
            this.betweenValue = true;
        }

        protected Criterion(String condition, Object value, Object secondValue) {
            this(condition, value, secondValue, null);
        }
    }
}